package com.study.pojo;

/**
 * @author dejawu
 * @Title: Stock
 * @Description: TODO
 * @date 2020/12/29
 */
public class Stock {

    //库存数量
    private static int num = 1;

    //减少库存数量的方法
    public boolean reduceStock(){
        if (num>0){
            num--;
            return true;
        }else {
            return false;
        }
    }
}
